package com.zjk.controller;

import com.zjk.ResultObject;
import com.zjk.dto.MemberLoginForm;
import com.zjk.service.UserSevice;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * @author: gfk
 * @create: 2022/10/28
 * @Description:
 * @FileName: UserController
 * @History:
 * @自定义内容：
 */
@RestController
@RequestMapping("/user")
public class UserController {
    @Autowired
    UserSevice userSevice;

    @PostMapping("/login")
    private ResultObject<Map> login(@RequestBody MemberLoginForm memberLoginForm){
        ResultObject<Map> login = userSevice.login(memberLoginForm);
        return login;
    }
}
